package com.hunttown.mes.rpc.domain;

import java.io.Serializable;
import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * created by wangjunfu on 2021-03-04 19:17:07
 */
public class IotAlarmTriggerDTO implements Serializable {
    private Integer id;
    private Integer entId;
    private Integer equipId;
    private Integer triggerId;
    private String eventName;
    private Date happenTime;
    private Date closeTime;
    private Integer solveId;
    private Date solveTime;
    private String solveProcess;
    private String mantunId;
    private String mantunType;
    private String mantunValue;
    private Integer mantunStatus;
    private Integer mantunNumber;
    private Integer stopFlag;
    private Integer deleteFlag;

    private String happenTimeSr;
    private String closeTimeSr;
    private String solveName;
    private String solveTimeSr;
    private String equipName;
    private String equipTypeName;
    private String triggerTypeName;
    private String triggerLevelName;
    private String alarmMethodName;
    private String eventType;   //曼顿通知生效

    //以下内容由Alt+Ins快捷生成

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getEntId() {
        return entId;
    }

    public void setEntId(Integer entId) {
        this.entId = entId;
    }

    public Integer getEquipId() {
        return equipId;
    }

    public void setEquipId(Integer equipId) {
        this.equipId = equipId;
    }

    public Integer getTriggerId() {
        return triggerId;
    }

    public void setTriggerId(Integer triggerId) {
        this.triggerId = triggerId;
    }

    public String getEventName() {
        return eventName;
    }

    public void setEventName(String eventName) {
        this.eventName = eventName;
    }

    public Date getHappenTime() {
        return happenTime;
    }

    public void setHappenTime(Date happenTime) {
        this.happenTime = happenTime;
    }

    public Date getCloseTime() {
        return closeTime;
    }

    public void setCloseTime(Date closeTime) {
        this.closeTime = closeTime;
    }

    public Integer getSolveId() {
        return solveId;
    }

    public void setSolveId(Integer solveId) {
        this.solveId = solveId;
    }

    public Date getSolveTime() {
        return solveTime;
    }

    public void setSolveTime(Date solveTime) {
        this.solveTime = solveTime;
    }

    public String getSolveProcess() {
        return solveProcess;
    }

    public void setSolveProcess(String solveProcess) {
        this.solveProcess = solveProcess;
    }

    public String getMantunId() {
        return mantunId;
    }

    public void setMantunId(String mantunId) {
        this.mantunId = mantunId;
    }

    public String getMantunType() {
        return mantunType;
    }

    public void setMantunType(String mantunType) {
        this.mantunType = mantunType;
    }

    public String getMantunValue() {
        return mantunValue;
    }

    public void setMantunValue(String mantunValue) {
        this.mantunValue = mantunValue;
    }

    public Integer getMantunStatus() {
        return mantunStatus;
    }

    public void setMantunStatus(Integer mantunStatus) {
        this.mantunStatus = mantunStatus;
    }

    public Integer getMantunNumber() {
        return mantunNumber;
    }

    public void setMantunNumber(Integer mantunNumber) {
        this.mantunNumber = mantunNumber;
    }

    public Integer getStopFlag() {
        return stopFlag;
    }

    public void setStopFlag(Integer stopFlag) {
        this.stopFlag = stopFlag;
    }

    public Integer getDeleteFlag() {
        return deleteFlag;
    }

    public void setDeleteFlag(Integer deleteFlag) {
        this.deleteFlag = deleteFlag;
    }

    public String getHappenTimeSr() {
        if (happenTimeSr == null || happenTimeSr.equals("")) {
            SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

            if (happenTime == null) {
                return "1990-01-01";
            } else {
                return df.format(new Date(happenTime.getTime()));
            }
        } else {
            return happenTimeSr;
        }
    }

    public void setHappenTimeSr(String happenTimeSr) {
        this.happenTimeSr = happenTimeSr;
    }

    public String getCloseTimeSr() {
        if (closeTimeSr == null || closeTimeSr.equals("")) {
            SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

            if (closeTime == null) {
                return "1990-01-01";
            } else {
                return df.format(new Date(closeTime.getTime()));
            }
        } else {
            return closeTimeSr;
        }
    }

    public void setCloseTimeSr(String closeTimeSr) {
        this.closeTimeSr = closeTimeSr;
    }

    public String getSolveName() {
        return solveName;
    }

    public void setSolveName(String solveName) {
        this.solveName = solveName;
    }

    public String getSolveTimeSr() {
        if (solveTimeSr == null || solveTimeSr.equals("")) {
            SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

            if (solveTime == null) {
                return "1990-01-01";
            } else {
                return df.format(new Date(solveTime.getTime()));
            }
        } else {
            return solveTimeSr;
        }
    }

    public void setSolveTimeSr(String solveTimeSr) {
        this.solveTimeSr = solveTimeSr;
    }

    public String getEquipName() {
        return equipName;
    }

    public void setEquipName(String equipName) {
        this.equipName = equipName;
    }

    public String getEquipTypeName() {
        return equipTypeName;
    }

    public void setEquipTypeName(String equipTypeName) {
        this.equipTypeName = equipTypeName;
    }

    public String getTriggerTypeName() {
        return triggerTypeName;
    }

    public void setTriggerTypeName(String triggerTypeName) {
        this.triggerTypeName = triggerTypeName;
    }

    public String getTriggerLevelName() {
        return triggerLevelName;
    }

    public void setTriggerLevelName(String triggerLevelName) {
        this.triggerLevelName = triggerLevelName;
    }

    public String getAlarmMethodName() {
        return alarmMethodName;
    }

    public void setAlarmMethodName(String alarmMethodName) {
        this.alarmMethodName = alarmMethodName;
    }

    public String getEventType() {
        return eventType;
    }

    public void setEventType(String eventType) {
        this.eventType = eventType;
    }
}